import http from '../request.js'

/* 
查询所有意见反馈
*/
export function selectAllFeedBack(data) {
  return http.request({
    url: '/admin/feedBack/selectAllFeedBack',
    method: 'post',
    data
  })
}

export function getOneFeedBack(data) {
  return http.request({
    url: '/admin/feedBack/getOneFeedBack?id=' + data,
    method: 'get'
  })
}
// 处理反馈
export function updateFeedBack(data) {
  return http.request({
    url: '/admin/feedBack/updateFeedBack?id=' + data,
    method: 'get'
  })
}

// 版本更新
export function addVersion(data) {
  return http.request({
    url: '/admin/version/addVersion',
    method: 'post',
    data
  })
}
export function selectAllVersion(data) {
  return http.request({
    url: '/admin/version/selectAllVersion',
    method: 'post',
    data
  })
}
export function getNewVersion(data) {
  return http.request({
    url: '/order/version/getNewVersion',
    method: 'get',
    data
  })
}

// 系统通知
/* 
查询系统消息列表
*/
export function selectAllMsg(data) {
  return http.request({
    url: '/admin/msg/selectAllMsg',
    method: 'post',
    data
  })
}

/* 
查询消息详情
*/
export function selectOneMsg(data) {
  return http.request({
    url: '/admin/msg/selectOneMsg?id=' + data,
    method: 'get'
  })
}

/* 
发布消息
*/
export function saveMsg(data) {
  return http.request({
    url: '/admin/msg/saveMsg',
    method: 'post',
    data
  })
}

export function sendMsg(data) {
  return http.request({
    url: '/admin/msg/saveMsg',
    method: 'post',
    data
  })
}

/* 
删除系统消息
*/
export function deleteMsg(data) {
  return http.request({
    url: '/admin/msg/deleteMsg',
    method: 'post',
    data
  })
}

/* 
查询短信列表*/

export function selectAllSms(data) {
  return http.request({
    url: '/admin/sms/selectAllSms',
    method: 'post',
    data
  })
}
/* 
发布短信*/

export function saveSms(data) {
  return http.request({
    url: '/admin/sms/saveSms',
    method: 'post',
    data
  })
}

/* 
删除短信*/

export function deleteSms(data) {
  return http.request({
    url: '/admin/sms/deleteSms',
    method: 'post',
    data
  })
}

// push列表
export function pushList(data) {
  return http.request({
    url: '/admin/unipush/pushList',
    method: 'get',
    params: data
  })
}
/* 
新增push*/

export function addPushActivity(data) {
  return http.request({
    url: '/admin/unipush/addPushActivity',
    method: 'post',
    data
  })
}
/* 
查看push*/

export function pushActivityWatch(data) {
  return http.request({
    url: '/admin/unipush/pushActivityWatch',
    method: 'get',
    params: data
  })
}

/* 
删除push*/

export function deletePushActivity(data) {
  return http.request({
    url: '/admin/unipush/deletePushActivity',
    method: 'post',
    data
  })
}
/* 查询push黑名单*/
export function queryPushBlackPhone(data) {
  return http.request({
    url: '/admin/unipush/queryPushBlackPhone',
    method: 'post',
    data
  })
}
/* 添加push黑名单*/
export function addPushBlackPhone(data) {
  return http.request({
    url: '/admin/unipush/addPushBlackPhone',
    method: 'post',
    data
  })
}

export function deletePushBlackPhone(data) {
  return http.request({
    url: '/admin/unipush/deletePushBlackPhone',
    method: 'post',
    data
  })
}
/* 查询城市*/
export function queryCity(data) {
  return http.request({
    url: '/admin/unipush/queryCity',
    method: 'get',
    params: data
  })
}
/* 上传*/
export function uploadExcel(data) {
  return http.request({
    url: '/admin/unipush/uploadExcel',
    method: 'post',
    data
  })
}
/* 下载模版*/
export function downExcel(data) {
  return http.request({
    url: '/admin/unipush/downExcel',
    method: 'post',
    data
  })
}
// selectNurseInfoCheckById
export function selectNurseInfoCheckById(data) {
  return http.request({
    url: '/admin/nurseInfoCheck/selectNurseInfoCheckById?id=224',
    method: 'get',
    data
  })
}
// 查询管理员
export function adminList(data) {
  return http.request({
    url: '/admin/adminDepartmentController/adminList',
    method: 'get',
    params: data
  })
}
// 管理员明细
export function adminDetail(data) {
  return http.request({
    url: '/admin/adminDepartmentController/adminDetail',
    method: 'get',
    params: data
  })
}
// 删除管理员
export function deleteAdminInfo(data) {
  return http.request({
    url: '/admin/adminDepartmentController/deleteAdminInfo',
    method: 'post',
    data
  })
}
// 添加
export function addAdminInfo(data) {
  return http.request({
    url: '/admin/adminDepartmentController/addAdminInfo',
    method: 'post',
    data
  })
}
// 编辑
export function editAdminInfo(data) {
  return http.request({
    url: '/admin/adminDepartmentController/editAdminInfo',
    method: 'post',
    data
  })
}

// 部门列表
export function deparmentList(data) {
  return http.request({
    url: '/admin/adminDepartmentController/deparmentList',
    method: 'get',
    params: data
  })
}
// 删除部门
export function deleteDeparment(data) {
  return http.request({
    url: '/admin/adminDepartmentController/deleteDeparment',
    method: 'post',
    data
  })
}
// 添加部门
export function editDeparmentInfo(data) {
  return http.request({
    url: '/admin/adminDepartmentController/editDeparmentInfo',
    method: 'post',
    data
  })
}
// 编辑部门
// editAdminInfo

// 角色列表
export function roleList(data) {
  return http.request({
    url: '/admin/adminRoleController/roleList',
    method: 'get',
    params: data
  })
}
// 菜单列表
export function menuList(data) {
  return http.request({
    url: '/admin/adminRoleController/menuList',
    method: 'get',
    params: data
  })
}
// 角色详情
export function roleDetail(data) {
  return http.request({
    url: '/admin/adminRoleController/roleDetail',
    method: 'get',
    params: data
  })
}

// 新增编辑角色
export function saveMenu(data) {
  return http.request({
    url: '/admin/adminRoleController/saveMenu',
    method: 'post',
    data
  })
}
// 删除角色
export function deleteRole(data) {
  return http.request({
    url: '/admin/adminRoleController/deleteRole',
    method: 'post',
    data
  })
}

// 通讯录列表
export function addressBookList(params) {
  return http.request({
    url: '/admin/addressBook/addressBookList',
    method: 'get',
    params
  })
}

// 新增编辑成员
export function addOrUpdateAddressBook(data) {
  return http.request({
    url: '/admin/addressBook/addOrUpdateAddressBook',
    method: 'post',
    data
  })
}

// 成员详情
export function addressBookDetail(params) {
  return http.request({
    url: '/admin/addressBook/addressBookDetail',
    method: 'get',
    params
  })
}

// 删除成员
export function deleteAddressBook(params) {
  return http.request({
    url: '/admin/addressBook/deleteAddressBook',
    method: 'get',
    params
  })
}

// 新增商渠道
export function insertInstitutionType(params) {
  return http.request({
    url: '/admin/institutionAccount/insertInstitutionType',
    method: 'get',
    params
  })
}

// 查询渠道列表
export function selectInstitutionTypeList(params) {
  return http.request({
    url: '/admin/institutionAccount/selectInstitutionTypeList',
    method: 'get',
    params
  })
}

// 根据渠道类型编号查询渠道账号列表
export function selectInstitutionAccountByTypeId(params) {
  return http.request({
    url: '/admin/institutionAccount/selectInstitutionAccountByTypeId',
    method: 'get',
    params
  })
}

// 新增渠道账号
export function insertInstitutionAccount(data) {
  return http.request({
    url: '/admin/institutionAccount/insertInstitutionAccount',
    method: 'post',
    data
  })
}
// 删除
export function deleteAccount(params) {
  return http.request({
    url: '/admin/institutionAccount/deleteAccount',
    method: 'get',
    params
  })
}
